<?php
if ( ! defined('BASEPATH')) exit('No direct script access allowed');
/**
 * -----------------------------------------------------
 *
 * manage login_log
 *
 * @package     manage
 * @subpackage  
 * @category    login_log -  登录日志
 * @author      ChenFu
 * @since       2016-6-18 version 1.0       
 * -----------------------------------------------------    
 */
class Login_log extends CI_Controller
{
	public function __construct()
	{
		parent::__construct();
		$this->load->helper('url');
		// 加载模型
		$this->load->model('login_model');
		// 检查是否登录
		check_login();
	}

	public function index()
	{
		// 分页
		$arr = array('page_total_num' => $this->login_model->get_all_num(),'every_page_num'=>20,'page_url_name'=>'page_id');
		$pager = $this->load->library('page',$arr);
		$data['pager']	  = $this->page->pages_all();	
		$data['login_log'] = $this->login_model->get_all_login_log($this->page->limit);
		$this->load->view('admin/login_log/list',$data);
	}
}